/*
  (C) 2005 Adam D. Bradley

  This program is free software; you can redistribute it and/or
  modify it under the terms of Version 2 of the GNU General Public 
  License.
  
  This library is distributed in the hope that it will be useful,
  but WITHOUT ANY WARRANTY; without even the implied warranty of
  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  General Public License for more details.
  
  You should have received a copy of the GNU Library General Public
  License along with this library; if not, write to the Free
  Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/

package step;

public class DanglingSplice extends Exception
{
	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;

	public DanglingSplice(step.Graph g, step.ReferenceNode n) { 
		DanglingGraph = g; 
		Dangler = n; 
	}

	step.ReferenceNode Dangler;
	step.Graph DanglingGraph;

	public String getMessage() { 
		return "Dangling Splice in Graph " + 
			DanglingGraph.GetID() + ": SpliceNode [" + 
			Dangler.GetID() + 
			"] targets non-extant ID [" + 
			Dangler.GetTarget() + "]";
	}
	/* DOME : add a method for sending notification to SD.
	   This should NOT be done automatically, since the
	   dangling splice may occur internally while post-parsing
	   a STEP document! */

}

